package com.fxm.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.fxm.domain.Question;
import com.fxm.returns.RespEntity;
import com.fxm.vo.param.OpenParam;
import com.fxm.vo.param.QuestionParam;
import com.fxm.vo.result.QuestionResult;
import com.fxm.vo.result.RuleResult;

import java.util.List;

/**
 * <p>
 * 答题 服务类
 * </p>
 *
 * @author fxm
 * @since 2021-01-07
 */
public interface QuestionService extends IService<Question> {
    /**
     * 共获积分
     * @return
     */
    RespEntity<Integer> getAllIntegral();
    /**
     * 答题规则
     * @return
     */
    RespEntity<RuleResult> getQuestionRule(OpenParam openParam);

    /**
     * 题目初始化
     * @return
     */
    RespEntity<QuestionResult> getQuestionInit();

    /**
     * 下一题
     * @param questionParam
     * @return
     */
    RespEntity<QuestionResult> getNextQuestion(QuestionParam questionParam);

    /**
     * 获取剩余挑战次数
     * @param openParam
     * @return
     */
    RespEntity<Integer> getChallengeNumbers(OpenParam openParam);

    /**
     * 挑战次数变更
     * @param openParam
     * @return
     */
    RespEntity updateChallengeNum(OpenParam openParam);
}
